fix: clang-tidy lint step fails when no csrc files change - #6049
fix: clang-tidy lint step fails when no csrc files change#6049andrewwhitecdw wants to merge 1 commit into
Conversation
Greptile SummaryThe PR prevents the clang-tidy job from failing when no relevant C++ files changed while preserving failures from Git file discovery.
Confidence Score: 5/5The PR appears safe to merge. No blocking failure remains. Important Files Changed
Reviews (2): Last reviewed commit: "fix: clang-tidy lint step fails when no ..." | Re-trigger Greptile |
Signed-off-by: andrewwhitecdw <andrewwhitecdw@users.noreply.github.com>
25a58fd to
fb668e1
Compare
|
@greptile-apps thanks for the review. I split the file-discovery pipeline into two steps: |
|
The fix looks correct. The separation is clean:
One minor nit: LGTM. Thanks for the clear explanation and the testing output. Tip: You can customize Greptile's behavior for this repo with |
This PR addresses the following issue in
.github/workflows/lint.yml: clang-tidy lint step fails when no csrc files change.Changes
.github/workflows/lint.yml: split changed-file discovery from the grep filter so thatgit difffailures are no longer swallowed by the|| trueguard.Details
The original single pipeline used
|| trueaftergrep, which also masked failures fromgit diff(e.g., an unavailable base revision). By capturinggit diffoutput first, a genuine file-discovery error now fails the step, whilegrepreturning no matches is still treated as an empty file list and skipslintrunnersafely.Testing
Validated the discovery logic locally with a temporary shell script:
No new test file is added because the repository does not currently have a workflow-syntax test harness; the validation above exercises the exact commands used in the workflow.